-
Notifications
You must be signed in to change notification settings - Fork 290
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Code Quality: Refactor code and make it more modern #1815
base: main
Are you sure you want to change the base?
Conversation
Apparently more necessary than I thought 😳
This comment was marked as outdated.
This comment was marked as outdated.
Can you explain what the purpose of this change is? |
There was a duplicate entry for the NuGet Gallery server, and the name for MyGet was wrong. |
I guess I'm wondering why MyGet was kept in lieu of NuGet |
The NuGet Gallery server is automatically enabled as a global package source in Visual Studio. Having it inside the nuget.config file would cause it to be duplicated. |
Essentially I think it would be best for IronPython to follow a similar structure as the .NET Runtime and Files:
|
This is why I hate submodules.. |
Yes, i thought about it too when i realized what @Lamparter means by
This notion is captured by the term Basically, there are the following projects to sort out:
Options:
My current preferences are (in order):
|
Your definition of Perhaps |
(again)
I had second thoughts about it. Not to put it back in But I am not particularly attached to this idea, placing StdLib in |
I hear you. Yes, luckily, we use |
Just more food for thought. I'm not sure if we have any tests covering IronPython running without the standard library, but I think it's layered in such a way that it might work without it (and IronPython.Modules?). Note that CPython has been moving features to Python implementations over the years and doesn't even run without the standard library. Whenever that happens we tend to drop the native implementation and use the Python one so maybe we'll get to a point where it's no longer possible to run stand-alone? |
I don't think that's a really good idea... |
Can you elaborate? |
Not that I know of.
It used to work, at least a few years ago (IDK about w/o IronPython.Modules), which I discovered accidentaly after forgetting to set IRONPYTHONPATH... There are some things that do not work properly (like that not all code paths can find the built-in codecs), but workarounds are known, issues are opened, and hopefully they will be fixed in the future.
Good point. Who knows how this will impact IronPython in the future. My favourite 😉 I've seen somewhere in the code (importlib boostrapper?) was a C# string containing a piece of Python code, compiled into the DLL and interpreted at runtime on start. Ingenious. |
What's gained in running without the standard library? |
in places i must have missed in IronLanguages#1813
manual....
NB IronPython already supports it since the interpreter engine and the standard library are distributed in separate NuGet packages. |
Absolutely no change whatsoever
I don't understand why the tests are failing 🫤
|
doesn't make a difference 😕
This path isn't specified anywhere, and the source code literally directs the tests to |
This one maybe? |
A few comments: Test issue: public TestManifest(Type parent) {
- var file = parent.Assembly.GetManifestResourceStream($"IronPythonTest.Cases.{parent.Name}Manifest.ini");
+ var file = parent.Assembly.GetManifestResourceStream($"IronPython.Tests.Cases.{parent.Name}Manifest.ini"); There's a bunch of files which had their perms altered from 100755 → 100644 (like
Not a fan of the
Otherwise it feels like it's almost there. Unfortunately I still can't review with GH because of the 3k file limit. Maybe we could split it up into smaller PRs, for example one with the non- |
Got it. |
Hello (again again)!
In this PR I've done the following:
Run Code Cleanup on the project - remove unnecessary using directives, format documents, etc.Run special advanced code cleanupSort out.editorconfig
...and various other changes that I will add here soon